<?php

/**
 * Lumad CMS
 * Copyright (c)	2007, Jason A. Banico
 *
 * Licensed under The MIT License
 * Redistributions of files must retain the above copyright notice.
 *
 * @filesource
 * @copyright		Copyright (c) 2007, Jason A. Banico
 * @link			http://cakeforge.org/projects/lumad-cms/
 * @package			lumad-cms
 * @license			http://www.opensource.org/licenses/mit-license.php The MIT License
 */

class User extends AppModel {
  var $name = 'User';
  
  var $hasOne = array('User_type' =>
                      array(
                            'className' => 'User_type',
                            'foreignKey' => 'user_id',
                            'dependent' => true
                      )
                );  

  var $validate = array(
    'username' => '/[a-z0-9\_\-]{3,}$/i',
    'username' => VALID_NOT_EMPTY,
    'password' => VALID_NOT_EMPTY,
  );

}
?>